package model;

public class Jar {
	private Integer quantityOfSeeds = 0;

	private Player player;

	public void setQuantityOfSeeds(Integer quantityOfSeeds) {
		this.quantityOfSeeds = quantityOfSeeds;
	}

	public Integer getQuantityOfSeeds() {
		return quantityOfSeeds;
	}

	public void setPlayer(Player player) {
		if (this.player != player) {
			Player old = this.player;
			this.player = player;
			if (old != null) {
				old.setJar(null);
			}
			if (player != null) {
				player.setJar(this);
			}
		}
	}

	public Player getPlayer() {
		return player;
	}

}
